/*
 * Error.h
 *
 *  Created on: 2011-2-25
 *      Author: hao
 */

#ifndef ERROR_H_
#define ERROR_H_

#include <exception>

#include <string>

namespace ErrorTag{

enum{

	MAINLOOP_CREATE_FAILED,
	GETTING_MAINLOOP_API_FAILED,
	CREATE_CONTEXT_FAILED,
	CONTEXT_FAILED,
	CREATE_STREAM_FAILED,
	STREAM_DRAIN_FAILED,
	DECODER_PLUGIN_DISAPPEAR,
	DECODER_LOADING_ERROR,
	DECODER_NOT_FIX,
	PLUGHIN_DATA_NOT_FOUND,
	MUSIC_FILE_NOT_FOUND,
	UNKNOWN_FILE_TYPE,
	UNKNOWN_FORMAT,
	CUE_SYTAX_ERROR,
	TRACK_TIME_ERROR,
        CUE_FILE_NOT_FOUND,

};

}

class Error{

	std::wstring wData;

	std::string Data;

public:

	Error( int Tag ) throw();

	const char * what() const;

	const wchar_t * w_what() const;

};

#endif /* ERROR_H_ */
